$(document).ready(function(){
   $("#changeGender").click(function(){
       sendChangeGender();
   }) ;
});

function sendChangeGender() {
   var gender = $("#dropdowngender").val();
   var nick = $("#dropdownnick").val();
   
   $.ajax({
      type: "POST",
      url: "ajax.php",
      data: {'nick' : nick, 'gender' : gender, 'changeGender' : 'changeGender'},
      success: function(msg) {
          $("#tra").html(msg);
      }
   });
}